package com.smart.reader.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.smart.reader.common.Page;
import com.smart.reader.exception.CustomException;
import com.smart.reader.model.bo.ClassInfoAddBo;
import com.smart.reader.model.bo.ClassInfoUpdateBo;
import com.smart.reader.model.po.ClassInfo;
import com.smart.reader.model.vo.ClassInfoVo;

public interface ClassInfoService extends IService<ClassInfo> {
    /**
     * 新增班级信息
     *
     * @param classInfo
     * @return
     * @throws CustomException
     */
    Boolean add(ClassInfoAddBo classInfo) throws CustomException;

    /**
     * 查询班级信息并分页
     *
     * @param pageNum
     * @param pageSize
     * @return
     */
    Page<ClassInfoVo> queryInfo(int pageNum, int pageSize);

    /**
     * 根据ID删除班级信息
     *
     * @param id
     * @return
     * @throws CustomException
     */
    Boolean delete(Long id) throws CustomException;

    /**
     * 修改班级数据
     *
     * @param classInfo
     * @return
     * @throws CustomException
     */
    Boolean edit(ClassInfoUpdateBo classInfo) throws CustomException;

    /**
     * 根据班级ID查询班级详情
     * 
     * @param id
     * @return
     */
    ClassInfoVo detail(Long id);
}
